import 'package:flutter/animation.dart';
import 'package:stop_watch_timer/stop_watch_timer.dart';

class ActionItem {
  int? createTime;
  int? updateTime;
  int? id;

  String? robotChannel;
  String? robotVersion;
  String? actionName;

  int? actionDuration;
  String? actionType;
  String? actionClass;

  String? resourceName;
  int? resourceType;
  String? actionIcon;

  String? actionPicture;
  String? actionStatement;
  String? productType;

  String? isNew;
  String? isOperation;
  String? md5;

  String? actionUrl;
  String? intentName;


  AnimationController? iconBtnController;
  AnimationController? signalController;

  bool isPlaying = false;

  StopWatchTimer? countDownWatchTimer;

  ActionItem() {}

  ActionItem.fromJson(Map<String, dynamic> json) {
    createTime = json['createTime'];
    updateTime = json['updateTime'];
    id = json['id'];

    robotChannel = json['robotChannel'];
    robotVersion = json['robotVersion'];
    actionName = json['actionName'];

    actionDuration = json['actionDuration'];
    actionType = json['actionType'];
    actionClass = json['actionClass'];

    resourceName = json['resourceName'];
    resourceType = json['resourceType'];
    actionIcon = json['actionIcon'];

    actionPicture = json['actionPicture'];
    actionStatement = json['actionStatement'];
    productType = json['productType'];

    isNew = json['isNew'];
    isOperation = json['isOperation'];
    md5 = json['md5'];

    actionUrl = json['actionUrl'];
    intentName = json['intentName'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['createTime'] = this.createTime;
    data['updateTime'] = this.updateTime;
    data['id'] = this.id;

    data['robotChannel'] = this.robotChannel;
    data['robotVersion'] = this.robotVersion;
    data['actionName'] = this.actionName;

    data['actionDuration'] = this.actionDuration;
    data['actionType'] = this.actionType;
    data['actionClass'] = this.actionClass;

    data['resourceName'] = this.resourceName;
    data['resourceType'] = this.resourceType;
    data['actionIcon'] = this.actionIcon;

    data['actionPicture'] = this.actionPicture;
    data['actionStatement'] = this.actionStatement;
    data['productType'] = this.productType;

    data['isNew'] = this.isNew;
    data['isOperation'] = this.isOperation;
    data['md5'] = this.md5;

    data['actionUrl'] = this.actionUrl;
    data['intentName'] = this.intentName;

    return data;
  }

}

